package hexagone.utils;

import static java.lang.Math.*;

public class DoublePair extends Paire<Double> {

    public final static DoublePair R1_1 = new DoublePair(1, 0);
    public final static DoublePair R2_1 = new DoublePair(0.5, -sqrt(3) / 2);
    public final static DoublePair R3_1 = new DoublePair(-0.5, -sqrt(3) / 2);
    public final static DoublePair R4_1 = new DoublePair(-1, 0);
    public final static DoublePair R5_1 = new DoublePair(-0.5, sqrt(3) / 2);
    public final static DoublePair R6_1 = new DoublePair(0.5, sqrt(3) / 2);
    public final static DoublePair R1_2 = R1_1.mult(2);
    public final static DoublePair R2_2 = R2_1.mult(2);
    public final static DoublePair R3_2 = R3_1.mult(2);
    public final static DoublePair R4_2 = R4_1.mult(2);
    public final static DoublePair R5_2 = R5_1.mult(2);
    public final static DoublePair R6_2 = R6_1.mult(2);
    public final static DoublePair[] R_1 = {R1_1, R2_1, R3_1, R4_1, R5_1, R6_1};
    public final static DoublePair[] R_2 = {R1_2, R2_2, R3_2, R4_2, R5_2, R6_2};
    
    public DoublePair() {
    
    }
    
    public DoublePair(double x, double y) {
        super(x, y);
    }
    
    public DoublePair mult(int fact) {
        return new DoublePair(x * fact, y * fact);
    }
}
